Generate and Print a Key as Split Components

Command:

Generate a random key, encrypt it under apropriate LMK, print it as two half components or three third components at the HSM attached printer.

Notes:

The HSM must be in the Authorised state.

A printer must be attached to the HSM Printer port or Auxiliary port.

The HSM must have a print format already defined.

The ESCON option does not return the second response message and its first response message is delayed until after printing has been completed. This is because the channel protocol allows only one response per request.

See Key Type Table to find key type code.

See Key Scheme Table for schemes available to encrypt keys.

For a single length key the key is split into two 8 character values ^P and ^Q in the print format denote the left and right halves respectively.

For a double length key ^P and ^Q in the print format denote the first and second key respectively.

For a triple length key ^P ,^Q and ^R in the print format denote the first, second and third key respectively.

^T in the print format denotes a key check value.

 

 

Field

Length & Type

Details

COMMAND MESSAGE

Message header

m A

(Subsequently returned to the Host unchanged).

Command code

2 A

Value NE.

Key type

3 H

Key type.

Key Scheme (LMK)

1 A

Key length / scheme for encrypting key under LMK. See section “Key Scheme Table”.

Print Field 0

n A

The print field defined as Print Field 0 in the print format definition (must not contain a “;” character).

Delimiter

1 A

Value “;”

Print Field 1

n A

The print field defined as Print Field 1 in the print format definition (must not contain a “;” character).

.

.

.

.

.

.

.

.

.

Last print field

n A

The last print field defined in the print format definition must not contain a “;” character).

End message delimiter

1 C

Optional. Must be present if a message trailer is present. Value X’19.

Message trailer

n A

Optional. Maximum length 32 characters.


 

Field

Length & Type

Details

RESPONSE MESSAGE (before printing)

Message header

n A

Returned to the Host unchanged.

Response code

2 A

Value NF.

Error code

2 N

00 : No Error

13 : LMK error; report to supervisor

15 : Error in input data

16 : Printer not ready/not connected

17 : Not in the Authorized state

18 : Format definition not loaded

Key

16H or
1A+32H or 1A+48H

Key encrypted under appropriate LMK.

Key check value

6 H

The key check value

End message delimiter

1 C

Present only if present in the command message. Value X’19.

Message trailer

n A

Present only if present in the command message. Maximum length 32 characters.

RESPONSE MESSAGE (after printing)

Message header

N A

Returned to the Host unchanged

Response code

2 A

Value NZ

Error code

2 N

00 : No errors

13 : LMK error, report to supervisor

16 : Printer not ready/disconnected

End message delimiter

1 C

Present only if present in the command message. Maximum length 32 characters